import request from '@/utils/request'

// 查询知识库书籍列表
export function listKnowledgeBaseBook(query) {
  return request({
    url: '/training/KnowledgeBaseBook/list',
    method: 'get',
    params: query
  })
}

// 查询知识库书籍详细
export function getKnowledgeBaseBook(id) {
  return request({
    url: '/training/KnowledgeBaseBook/' + id,
    method: 'get'
  })
}

// 新增知识库书籍
export function addKnowledgeBaseBook(data) {
  return request({
    url: '/training/KnowledgeBaseBook',
    method: 'post',
    data: data
  })
}

// 修改知识库书籍
export function updateKnowledgeBaseBook(data) {
  return request({
    url: '/training/KnowledgeBaseBook',
    method: 'put',
    data: data
  })
}

// 删除知识库书籍
export function delKnowledgeBaseBook(id) {
  return request({
    url: '/training/KnowledgeBaseBook/' + id,
    method: 'delete'
  })
}
